function foo () {
  var name = "yz"
  var num = 123  //V8引擎会优化，将num的值给销毁
  function test() {
    console.log(name)
    // console.log(num)
  }
  return test
}

var yz = foo()
yz()

